﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.EntityFrameworkCore;

namespace WCS.Infrastructure.EFCore;

/// <summary>
/// 支付平台表
/// </summary>
[Index("Name", Name = "IX_AiCollection_PaymentPlatforms_Name", IsUnique = true)]
public partial class PaymentPlatform
{
    /// <summary>
    /// 支付平台ID
    /// </summary>
    [Key]
    [StringLength(32)]
    public string Id { get; set; } = null!;

    /// <summary>
    /// 名称
    /// </summary>
    [StringLength(256)]
    public string Name { get; set; } = null!;

    /// <summary>
    /// 备注
    /// </summary>
    [StringLength(2048)]
    public string? Description { get; set; }

    /// <summary>
    /// 平台编号
    /// </summary>
    [StringLength(32)]
    public string? Code { get; set; }

    /// <summary>
    /// 是否接单
    /// </summary>
    public bool? AcceptOrder { get; set; }

    /// <summary>
    /// 收单服务商ID
    /// </summary>
    [StringLength(20)]
    public string? AcqSpId { get; set; }

    /// <summary>
    /// 应用ID
    /// </summary>
    [StringLength(100)]
    public string? AppId { get; set; }

    /// <summary>
    /// 回调URL
    /// </summary>
    [StringLength(500)]
    public string? CallbackUrl { get; set; }

    /// <summary>
    /// 密钥
    /// </summary>
    [StringLength(100)]
    public string? SecretKey { get; set; }

    /// <summary>
    /// 扩展属性
    /// </summary>
    public string ExtraProperties { get; set; } = null!;

    /// <summary>
    /// 并发标记
    /// </summary>
    [StringLength(40)]
    public string ConcurrencyStamp { get; set; } = null!;

    /// <summary>
    /// 创建时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime CreationTime { get; set; }

    /// <summary>
    /// 创建者ID
    /// </summary>
    [StringLength(32)]
    public string? CreatorId { get; set; }

    /// <summary>
    /// 最后修改时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? LastModificationTime { get; set; }

    /// <summary>
    /// 修改者ID
    /// </summary>
    [StringLength(32)]
    public string? LastModifierId { get; set; }

    /// <summary>
    /// 是否删除
    /// </summary>
    public bool IsDeleted { get; set; }

    /// <summary>
    /// 删除者ID
    /// </summary>
    [StringLength(32)]
    public string? DeleterId { get; set; }

    /// <summary>
    /// 删除时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? DeletionTime { get; set; }

    /// <summary>
    /// 启用状态
    /// </summary>
    public int EnableStatus { get; set; }

    /// <summary>
    /// 激活状态
    /// </summary>
    public int ActivationStatus { get; set; }

    /// <summary>
    /// 级联ID
    /// </summary>
    [StringLength(2048)]
    public string? CascadeId { get; set; }

    /// <summary>
    /// 审核消息
    /// </summary>
    [StringLength(400)]
    public string? ApproveMessage { get; set; }

    /// <summary>
    /// Epaylinks审核通过时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? EpaylinksApprovedTime { get; set; }

    /// <summary>
    /// Epaylinks审核通知时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? EpaylinksAuditNotificationTime { get; set; }

    /// <summary>
    /// Epaylinks业务通知时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? EpaylinksBusinessNotificationTime { get; set; }

    /// <summary>
    /// Epaylinks首次申请时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? EpaylinksFirstApplyTime { get; set; }

    /// <summary>
    /// Epaylinks最后申请时间
    /// </summary>
    [Column(TypeName = "timestamp(6) without time zone")]
    public DateTime? EpaylinksLastApplyTime { get; set; }

    /// <summary>
    /// 商户类型
    /// </summary>
    public int MerchantType { get; set; }

    /// <summary>
    /// 账户余额
    /// </summary>
    public long Balance { get; set; }

    /// <summary>
    /// 虚拟余额
    /// </summary>
    public long VirtualBalance { get; set; }

    /// <summary>
    /// 可提现余额
    /// </summary>
    public long WithdrawableBalance { get; set; }

    /// <summary>
    /// 提现方式
    /// </summary>
    public int WithdrawalMethod { get; set; }

    /// <summary>
    /// 未结算余额
    /// </summary>
    public long UnsettledBalance { get; set; }
}
